/* eslint valid-jsdoc: "off" */

'use strict';

/**
 * @param {Egg.EggAppInfo} appInfo app info
 */
module.exports = appInfo => {
  /**
   * built-in config
   * @type {Egg.EggAppConfig}
   **/
  const config = exports = {};

  // use for cookie sign key, should change to your own and keep security
  config.keys = appInfo.name + '_1608777530005_1177';

  // add your middleware config here
  config.middleware = [
	  'exceptionHandler'
  ];

  // add your user config here
  const userConfig = {
    // myAppName: 'egg',
  };

	config.mysql = {
		client: {
			// host
			host: '47.105.118.254',
			// 端口号
			port: '3306',
			// 用户名
			user: 'root',
			// 密码
			password: 'Xcp,./29841311',
			// 数据库名
			database: 'egg'
		},
		// 是否加载到 app 上，默认开启
		app: true,
		// 是否加载到 agent 上，默认关闭
		agent: false
	}

	config.security ={
		xframe: {
			enable: false,
		},
		csrf: {
			enable: false,
		}
	}



  return {
    ...config,
    ...userConfig,
  };
};
